/* 
 * Copyright [2017] [Alex/LiBo(libo2dev.aliyun.com/alex.link@foxmail.com)]
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.hyts.bmsp.record;

import java.util.Map;

/**  
 * @Title BaseModel.java  
 * @Package com.hyts.bmsp.record  
 * @Description 基础模型对象类  
 * @author LiBo/Alex  
 * @date 2017年12月24日  
 * @version V1.0  
 */
public class BaseModel {
	
	/**  
	 * @Fields field:field:关键字  
	 */ 
	private String id;
	
	/**  
	 * @Fields field:field:表名 
	 */ 
	private String tableName;
	
	/**  
	 * @Fields field:field:键值对 
	 */ 
	private Map<String,Object> nameAndValueMap;
	
	/**  
	 * @Fields field:field:批次号 
	 */ 
	private int batchSize = 100;
	
	/**  
	 * @Fields field:field:返回新字段
	 */ 
	private String[] returnField;

	/**  
	 * @return id  
	 */
	public String getId() {
		return id;
	}

	/**  
	 * @param paramtheparamthe{bare_field_name} to set  
	 */
	public void setId(String id) {
		this.id = id;
	}

	/**  
	 * @return tableName  
	 */
	public String getTableName() {
		return tableName;
	}

	/**  
	 * @param paramtheparamthe{bare_field_name} to set  
	 */
	public void setTableName(String tableName) {
		this.tableName = tableName;
	}

	/**  
	 * 创建一个新的实例-构造器 BaseModel.  
	 * @param id
	 * @param tableName  
	 */ 
	public BaseModel(String id, String tableName) {
		super();
		this.id = id;
		this.tableName = tableName;
	}

	/**  
	 * 创建一个新的实例-构造器 BaseModel.    
	 */ 
	public BaseModel() {
		super();
	}
	
	/**  
	 * 创建一个新的实例-构造器 BaseModel.  
	 * @param tableName  
	 */ 
	public BaseModel(String tableName) {
		super();
		this.tableName = tableName;
	}

	/**  
	 * 创建一个新的实例-构造器 BaseModel.  
	 * @param id
	 * @param tableName
	 * @param nameAndValueMap  
	 */ 
	public BaseModel(String id, String tableName, Map<String, Object> nameAndValueMap) {
		super();
		this.id = id;
		this.tableName = tableName;
		this.nameAndValueMap = nameAndValueMap;
	}

	/**  
	 * @return nameAndValueMap  
	 */
	public Map<String, Object> getNameAndValueMap() {
		return nameAndValueMap;
	}

	/**  
	 * @param paramtheparamthe{bare_field_name} to set  
	 */
	public void setNameAndValueMap(Map<String, Object> nameAndValueMap) {
		this.nameAndValueMap = nameAndValueMap;
	}

	/**  
	 * 创建一个新的实例-构造器 BaseModel.  
	 * @param id
	 * @param tableName
	 * @param nameAndValueMap
	 * @param batchSize  
	 */ 
	public BaseModel(String id, String tableName, Map<String, Object> nameAndValueMap, int batchSize) {
		super();
		this.id = id;
		this.tableName = tableName;
		this.nameAndValueMap = nameAndValueMap;
		this.batchSize = batchSize;
	}

	/**  
	 * @return batchSize  
	 */
	public int getBatchSize() {
		return batchSize;
	}

	/**  
	 * @param paramtheparamthe{bare_field_name} to set  
	 */
	public void setBatchSize(int batchSize) {
		this.batchSize = batchSize;
	}

	/**  
	 * 创建一个新的实例-构造器 BaseModel.  
	 * @param id
	 * @param tableName
	 * @param nameAndValueMap
	 * @param batchSize
	 * @param returnField  
	 */ 
	public BaseModel(String id, String tableName, Map<String, Object> nameAndValueMap, int batchSize,
			String[] returnField) {
		super();
		this.id = id;
		this.tableName = tableName;
		this.nameAndValueMap = nameAndValueMap;
		this.batchSize = batchSize;
		this.returnField = returnField;
	}

	/**  
	 * @return returnField  
	 */
	public String[] getReturnField() {
		return returnField;
	}

	/**  
	 * @param paramtheparamthe{bare_field_name} to set  
	 */
	public void setReturnField(String[] returnField) {
		this.returnField = returnField;
	}
	
	
	
}
